package db.pojo;

import java.util.*;
import java.text.SimpleDateFormat;
import db.ext.Ea_demo_bymxbExt;
@SuppressWarnings("unchecked")
/**
 * ea_demo_bymxb
 */
public class Ea_demo_bymxb {
	/**
	 * SXH
	 */
	public String sXH;
	/**
	 * XH
	 */
	public String xH;
	/**
	 * ZFLB
	 */
	public String zFLB;
	/**
	 * GRBM
	 */
	public String gRBM;
	/**
	 * XM
	 */
	public String xM;
	/**
	 * SFDLMC
	 */
	public String sFDLMC;
	/**
	 * SFXMMC
	 */
	public String sFXMMC;
	/**
	 * SL
	 */
	public double sL;
	/**
	 * SJJG
	 */
	public double sJJG;
	/**
	 * FYZE
	 */
	public double fYZE;
	/**
	 * CD
	 */
	public String cD;
	/**
	 * GG
	 */
	public String gG;
	/**
	 * SFSJ
	 */
	public java.util.Date sFSJ;
	/**
	 * SFY
	 */
	public String sFY;
	SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
	public static Ea_demo_bymxbExt DB = new Ea_demo_bymxbExt(); 
	
	public Ea_demo_bymxb() {
		super();
	}
	
	public Ea_demo_bymxb(String sXH, String xH, String zFLB, String gRBM, String xM, String sFDLMC, String sFXMMC, double sL, double sJJG, double fYZE, String cD, String gG, java.util.Date sFSJ, String sFY) {
		super();
		this.sXH = sXH; 
		this.xH = xH; 
		this.zFLB = zFLB; 
		this.gRBM = gRBM; 
		this.xM = xM; 
		this.sFDLMC = sFDLMC; 
		this.sFXMMC = sFXMMC; 
		this.sL = sL; 
		this.sJJG = sJJG; 
		this.fYZE = fYZE; 
		this.cD = cD; 
		this.gG = gG; 
		this.sFSJ = sFSJ; 
		this.sFY = sFY; 
	}
	
	public String getSXH() {
		return sXH;
	}

	public void setSXH(String sXH) {
		this.sXH = sXH;
	} 
	
	public String getXH() {
		return xH;
	}

	public void setXH(String xH) {
		this.xH = xH;
	} 
	
	public String getZFLB() {
		return zFLB;
	}

	public void setZFLB(String zFLB) {
		this.zFLB = zFLB;
	} 
	
	public String getGRBM() {
		return gRBM;
	}

	public void setGRBM(String gRBM) {
		this.gRBM = gRBM;
	} 
	
	public String getXM() {
		return xM;
	}

	public void setXM(String xM) {
		this.xM = xM;
	} 
	
	public String getSFDLMC() {
		return sFDLMC;
	}

	public void setSFDLMC(String sFDLMC) {
		this.sFDLMC = sFDLMC;
	} 
	
	public String getSFXMMC() {
		return sFXMMC;
	}

	public void setSFXMMC(String sFXMMC) {
		this.sFXMMC = sFXMMC;
	} 
	
	public double getSL() {
		return sL;
	}

	public void setSL(double sL) {
		this.sL = sL;
	} 
	
	public void changeSLWith(double sL){
		this.sL += sL;
	}
	
	public void changeSLWithMin(double sL,double min){
		this.sL += sL;
		this.sL = this.sL < min ? min : this.sL;
	}
	
	public void changeSLWithMax(double sL,double max){
		this.sL += sL;
		this.sL = this.sL > max ? max : this.sL;
	}
	
	public void changeSLWithMaxMin(double sL,double max,double min){
		this.sL += sL;
		this.sL = this.sL < min ? min : this.sL;
		this.sL = this.sL > max ? max : this.sL;
	}	
	public double getSJJG() {
		return sJJG;
	}

	public void setSJJG(double sJJG) {
		this.sJJG = sJJG;
	} 
	
	public void changeSJJGWith(double sJJG){
		this.sJJG += sJJG;
	}
	
	public void changeSJJGWithMin(double sJJG,double min){
		this.sJJG += sJJG;
		this.sJJG = this.sJJG < min ? min : this.sJJG;
	}
	
	public void changeSJJGWithMax(double sJJG,double max){
		this.sJJG += sJJG;
		this.sJJG = this.sJJG > max ? max : this.sJJG;
	}
	
	public void changeSJJGWithMaxMin(double sJJG,double max,double min){
		this.sJJG += sJJG;
		this.sJJG = this.sJJG < min ? min : this.sJJG;
		this.sJJG = this.sJJG > max ? max : this.sJJG;
	}	
	public double getFYZE() {
		return fYZE;
	}

	public void setFYZE(double fYZE) {
		this.fYZE = fYZE;
	} 
	
	public void changeFYZEWith(double fYZE){
		this.fYZE += fYZE;
	}
	
	public void changeFYZEWithMin(double fYZE,double min){
		this.fYZE += fYZE;
		this.fYZE = this.fYZE < min ? min : this.fYZE;
	}
	
	public void changeFYZEWithMax(double fYZE,double max){
		this.fYZE += fYZE;
		this.fYZE = this.fYZE > max ? max : this.fYZE;
	}
	
	public void changeFYZEWithMaxMin(double fYZE,double max,double min){
		this.fYZE += fYZE;
		this.fYZE = this.fYZE < min ? min : this.fYZE;
		this.fYZE = this.fYZE > max ? max : this.fYZE;
	}	
	public String getCD() {
		return cD;
	}

	public void setCD(String cD) {
		this.cD = cD;
	} 
	
	public String getGG() {
		return gG;
	}

	public void setGG(String gG) {
		this.gG = gG;
	} 
	
	public java.util.Date getSFSJ() {
		return sFSJ;
	}

	public void setSFSJ(java.util.Date sFSJ) {
		this.sFSJ = sFSJ;
	} 
	
	public String getSFY() {
		return sFY;
	}

	public void setSFY(String sFY) {
		this.sFY = sFY;
	} 
	
	
	public Map ea_demo_bymxbToMap() {
		Map map = new HashMap();
		try {
			map.put("sXH",this.sXH);
			map.put("xH",this.xH);
			map.put("zFLB",this.zFLB);
			map.put("gRBM",this.gRBM);
			map.put("xM",this.xM);
			map.put("sFDLMC",this.sFDLMC);
			map.put("sFXMMC",this.sFXMMC);
			map.put("sL",this.sL);
			map.put("sJJG",this.sJJG);
			map.put("fYZE",this.fYZE);
			map.put("cD",this.cD);
			map.put("gG",this.gG);
			map.put("sFSJ",simpleDateFormat.format(this.sFSJ));
			map.put("sFY",this.sFY);
		} catch (Exception e) {
			e.printStackTrace();
		}
		return map;
	}

	public Ea_demo_bymxb mapToEa_demo_bymxb(Map map){
		try {
			String sXH =  map.get("sXH").toString();
			String xH =  map.get("xH").toString();
			String zFLB =  map.get("zFLB").toString();
			String gRBM =  map.get("gRBM").toString();
			String xM =  map.get("xM").toString();
			String sFDLMC =  map.get("sFDLMC").toString();
			String sFXMMC =  map.get("sFXMMC").toString();
			double sL = Double.parseDouble( map.get("sL").toString());
			double sJJG = Double.parseDouble( map.get("sJJG").toString());
			double fYZE = Double.parseDouble( map.get("fYZE").toString());
			String cD =  map.get("cD").toString();
			String gG =  map.get("gG").toString();
			java.util.Date sFSJ = simpleDateFormat.parse( map.get("sFSJ").toString());
			String sFY =  map.get("sFY").toString();
			Ea_demo_bymxb ea_demo_bymxb = new Ea_demo_bymxb(sXH, xH, zFLB, gRBM, xM, sFDLMC, sFXMMC, sL, sJJG, fYZE, cD, gG, sFSJ, sFY);
			return ea_demo_bymxb;
		} catch (Exception e) {
			e.printStackTrace();
			return null;
		}
	} 
	
	public String toString(){
		return ea_demo_bymxbToMap().toString();
	}
	
	//方便数据操作	
	public Ea_demo_bymxb insert(){
		return DB.insert(this);
	}
	public Ea_demo_bymxb update(){
		return DB.update(this);
	}
	
	public int delete(){
		return DB.delete(this);
	}
	
}
